# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.ToolResults.V1beta3.Model.NonSdkApi do
  @moduledoc """
  A non-sdk API and examples of it being called along with other metadata See https://developer.android.com/distribute/best-practices/develop/restrictions-non-sdk-interfaces

  ## Attributes

  *   `apiSignature` (*type:* `String.t`, *default:* `nil`) - The signature of the Non-SDK API
  *   `exampleStackTraces` (*type:* `list(String.t)`, *default:* `nil`) - Example stack traces of this API being called.
  *   `insights` (*type:* `list(GoogleApi.ToolResults.V1beta3.Model.NonSdkApiInsight.t)`, *default:* `nil`) - Optional debugging insights for non-SDK API violations.
  *   `invocationCount` (*type:* `integer()`, *default:* `nil`) - The total number of times this API was observed to have been called.
  *   `list` (*type:* `String.t`, *default:* `nil`) - Which list this API appears on
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :apiSignature => String.t() | nil,
          :exampleStackTraces => list(String.t()) | nil,
          :insights => list(GoogleApi.ToolResults.V1beta3.Model.NonSdkApiInsight.t()) | nil,
          :invocationCount => integer() | nil,
          :list => String.t() | nil
        }

  field(:apiSignature)
  field(:exampleStackTraces, type: :list)
  field(:insights, as: GoogleApi.ToolResults.V1beta3.Model.NonSdkApiInsight, type: :list)
  field(:invocationCount)
  field(:list)
end

defimpl Poison.Decoder, for: GoogleApi.ToolResults.V1beta3.Model.NonSdkApi do
  def decode(value, options) do
    GoogleApi.ToolResults.V1beta3.Model.NonSdkApi.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.ToolResults.V1beta3.Model.NonSdkApi do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
